'''
Created on Dec 26, 2011

@author: haoyu
'''
class Test:
  def __init__(self):
    pass
  
  def getkey(self,x,y,z):
    return "key:%s,%s,%s"%(x,y,z);
  def m1(self,key):
      print "m1:%s"%key
  
  def m2(self):
      print "m2"
      fun = getattr(self,"m1")
      fun("key")
      print self.getkey(1,2,3)
        
def key2(x,y,z):
  return "key2"
if __name__ == "__main__":
    t = Test()
    t.getkey = lambda x,y,z:"key2:%s,%s"%(x,y)
    print t.m2()
    